package com.nononsenseapps.feeder.db

//import androidx.sqlite.db.SupportSQLiteProgram
//import com.nononsenseapps.feeder.db.room.TAGS_SEARCH
/*
import androidx.sqlite.db.SupportSQLiteQuery
import cn.ekuma.odbo.mobile.toWhereSQL
import com.gitee.wsl.db.dsl.query.QBF


object RoomDbHelper {
    */
/*fun  loadLiveUnreadPreviewsWithTags(searchTextList:List<String>,unRead:Boolean,itemDao: FeedItemDao): LivePagedListBuilder<Int, PreviewItem>{
        val qbf= QBF.c().eq(FEED_ITEM.tableColumn(FEED_ITEM.COL_UNREAD),unRead)
        searchTextList.forEach{str -> qbf.like(FEED_ITEM.tableColumn(FEED_ITEM.COL_ITEM_TAGS),str)}
        return LivePagedListBuilder(itemDao.loadLiveUnreadPreviewsWithTags(SampleQuery(TAGS_SEARCH.replace(":searchText:",qbf.toWhereSQL()))), PAGE_SIZE)
    }*//*


    fun createTagsQueryWhere(searchTextList:List<String>):String{
        val qbf= QBF.c()
        searchTextList.forEach{str -> qbf.like(FEED_ITEM.tableColumn(FEED_ITEM.COL_ITEM_TAGS),str)}
        return qbf.toWhereSQL()
    }
}

open class SampleQuery(override val sql:String, override val argCount: Int=0) : SupportSQLiteQuery{
    override fun bindTo(statement: SupportSQLiteProgram) {
    }

}*/
